<span class="avatar">
    <?php if(isset($this->author)):?>
    <a href="<?php echo $this->author->url->default;?>">
        <img src="<?php echo $this->author->avatar->small;?>" 
             alt="<?php echo $this->author->nickname;?>" /></a>
    <?php endif;?>
</span>